<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	<form action="cp_findByPName">
		搜索产品名:<input name="pro_name" value=""/><input type="submit">
	</form>
	<table>
		<tr>
			<td>商品名</td>
			<td>公司名</td>
			<td>产品详情</td>
		</tr>
		<c:choose>
			<c:when test="${pblist==null }">
				<tr>
					<td align="center">没有你所查找的类</td>
				</tr>
			</c:when>
			<c:otherwise>
				<c:forEach items="${pblist.list }" var="cp">
					<tr>
						<td>${cp.product.pro_name }</td>
						<td>${cp.company.comp_name }</td>
						<td>${cp.info }</td>
					</tr>
				</c:forEach>
			</c:otherwise>
		</c:choose>
	</table>
</body>
</html>